package extend.抽象方法;

public abstract class demo {
    String str;
    static int i;

    public static void test1() {

    }

    public void test2() {

    }

    public abstract void test3();

    public static void main(String[] args) {
        new demo() {
            @Override
            public void test3() {
                System.out.println("test3");
            }
        };
    }
}

class demo2 extends demo {
    @Override
    public void test3() {
        System.out.println("test3");
    }
}